<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@ include file="../base_top.jsp" %>

<!DOCTYPE HTML>
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>欢迎注册</title>
	<%@ include file="../base_head.jsp" %>
	<link rel="stylesheet" type="text/css" href="<%=basePath%>css/user/reg_style.css">
	<script type="text/javascript" src="<%=basePath%>js/jquery-1.12.3.js"></script>
	<script type="text/javascript">
        var code; //在全局 定义验证码
        function createCode() {
            code = "";
            var codeLength = 4;//验证码的长度
            var checkCode = document.getElementById("reg_code");
            var selectChar = new Array(0, 1, 2, 3, 4, 5, 6, 7, 8, 9,'A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z');//所有候选组成验证码的字符，当然也可以用中文的

            for (var i = 0; i < codeLength; i++) {
                var charIndex = Math.floor(Math.random() * 36);
                code += selectChar[charIndex];
            }
            //alert(code);
            if (checkCode) {
                checkCode.className = "reg_code";
                checkCode.value = code;
            }
        }
    </script>
    <script type="text/javascript">
    	
    
    
    
    
    </script>
  </head>
  
<body onload="createCode()">
<div class="reg_taitou">
    <img src="//img.zscaling.xyz:8080/logo/logo_03.jpg">
    <div class="welcome">&nbsp;欢&nbsp;迎&nbsp;注&nbsp;册&nbsp;</div>
    <div class="other">已有账号<a href="#">请登录</a></div>
</div>
<div class="reg_mainbody">
	<form action="reg/eRegister" method="post">
    <div class="main_con">
        <div class="id"><div class="font"> 用 户 名</div><input type="text" name="user.userName" required="required"></div>
        <div class="prompt" id="id">长度只能在1-10个字符之间</div>
        <div class="pwd"><div class="font">设置密码</div><input type="password" name="user.userPasswd" required="required"></div>
        <div class="prompt" id="pwd"></div>
        <div class="re_pwd"><div class="font">确认密码</div><input type="password" name="rePasswd" required="required"></div>
        <div class="prompt" id="re_pwd"></div>
        <div class="mail"><div class="font">邮箱验证</div><input type="email" name="user.userEmail" required="required"></div>
        <div class="prompt" id="mail"></div>
        <div class="phone">
        <div class="font">
        <select><option value="中国+86">中国+86</option><option value="中国+86">中国+86</option><option value="中国+86">中国+86</option></select>
        </div>
        <input type="tel" name="user.userPhone" required="required">
        </div>
        <div class="prompt" id="phone"></div>
        <div class="num"><div class="font">验 证 码</div>
            <input type="text" required="required" class="phone_num_input">
            <input type="text" readonly class="num_submit" id="reg_code" onclick="createCode()" style="width: 18%; float:left; margin: 0; padding: 0;">
        </div>
        <div class="prompt" id="num"></div>
        <div class="phone_num"><div class="font">手机验证码</div>
            <input type="text" required="required" class="phone_num_input">
            <input type="submit" value="获取验证码" class="phone_num_submit"></div>
        <div class="prompt" id="phone_num"></div>
        <div class="degree"><input type="checkbox" checked="checked" style="width:16px;height:16px; line-height:50px;">我已阅读并同意<a href="#">《中华精品网用户注册协议》</a> </div>
        <div class="btn"><input type="submit" value="立即注册" id="sub_btn"></div>
    </div>
	</form>
</div>
</body>
</html>
